Delay in the WAM and the TOAM: redoing a ten year old experiment
نویسندگان
چکیده
A 10 year old experiment related to freeze/2 and its implementation in B-Prolog and SICStus Prolog is redone. B-Prolog uses the TOAM abstract machine and its implementation of delayed goals is by means of suspension frames on the execution stack. The traditional WAM approach partly established by SICStus Prolog implementors is to put suspension terms on the heap. Earlier experiments comparing the two approaches/systems indicated a clear edge for the B-Prolog approach. We first redo these experiments and show to what extent the old conclusions still hold after 10 years. Subsequently, we use hProlog as an environment for showing to what extent the traditional WAM approach to freeze/2 can be made competitive to the B-Prolog approach. We do the same for the event mechanism of B-Prolog. Delay in the WAM and the TOAM: redoing a ten year old experiment Bart Demoen and Phuong-Lan Nguyen ∗ Dept. of Computer Science, K.U.Leuven, Belgium [email protected] † Inst. de Mathématiques Appliquées, UCO, Angers, France [email protected] Abstract. A 10 year old experiment related to freeze/2 and its implementation in B-Prolog and SICStus Prolog is redone. B-Prolog uses the TOAM abstract machine and its implementation of delayed goals is by means of suspension frames on the execution stack. The traditional WAM approach partly established by SICStus Prolog implementors is to put suspension terms on the heap. Earlier experiments comparing the two approaches/systems indicated a clear edge for the B-Prolog approach. We first redo these experiments and show to what extent the old conclusions still hold after 10 years. Subsequently, we use hProlog as an environment for showing to what extent the traditional WAM approach to freeze/2 can be made competitive to the B-Prolog approach. We do the same for the event mechanism of B-Prolog. A 10 year old experiment related to freeze/2 and its implementation in B-Prolog and SICStus Prolog is redone. B-Prolog uses the TOAM abstract machine and its implementation of delayed goals is by means of suspension frames on the execution stack. The traditional WAM approach partly established by SICStus Prolog implementors is to put suspension terms on the heap. Earlier experiments comparing the two approaches/systems indicated a clear edge for the B-Prolog approach. We first redo these experiments and show to what extent the old conclusions still hold after 10 years. Subsequently, we use hProlog as an environment for showing to what extent the traditional WAM approach to freeze/2 can be made competitive to the B-Prolog approach. We do the same for the event mechanism of B-Prolog.
منابع مشابه
Environment Reuse in the WAM
The TOAM reuses eagerly allocated stack frames, while the WAM avoids to allocate environments. This is investigated by using the tak/4 benchmark as an inital case study for better understanding what one can expect from environment reuse for deterministic predicates in the WAM. Additionally, artificial programs are used to amplify the findings. The experiment compares the impact of reusing an en...
متن کاملTR-2003014: A High-Performance Abstract Machine for Prolog and Its Extensions
This paper describes the design and the implementation of the TOAM (Tree-Oriented Abstract Machine) for Prolog and its extensions. The TOAM, as a Prolog machine, is based on the famous WAM model but differs from it in argument passing, stack management, and clause indexing. The original TOAM for Prolog was designed over ten years ago and the architecture was published in ACM TOPLAS in 1996 [26]...
متن کاملThe language features and architecture of B-Prolog
B-Prolog is a high-performance implementation of the standard Prolog language with several extensions including matching clauses, action rules for event handling, finite-domain constraint solving, arrays and hash tables, declarative loop constructs, and tabling. The B-Prolog system is based on the TOAM architecture which differs from the WAM mainly in that (1) arguments are passed old-fashioned...
متن کاملA Register-Free Abstract Prolog Machine with Jumbo Instructions
Almost all current Prolog systems are based on the Warren Abstract Machine (WAM), in which registers are used to pass procedure arguments and store temporary variables. In this paper, we present a stack machine for Prolog, named TOAM Jr., which departs from the TOAM adopted in early versions of B-Prolog in that it employs no registers for arguments or temporary variables, and offers variable-si...
متن کاملTR-2007024: A Register-free Abstract Prolog Machine with Jumbo Instructions
Almost all current Prolog systems are based on the Warren Abstract Machine (WAM), in which registers are used to pass procedure arguments and store temporary variables. In this paper, we present a stack machine for Prolog, named TOAM Jr., which departs from the TOAM adopted in early versions of B-Prolog in that it employs no registers for arguments or temporary variables, and offers variable-si...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 2006